\hypertarget{routines_o_8h}{
\section{/Users/carloshergar/optica/Plasmas/rana-pic/trunk/include/routinesO.h File Reference}
\label{routines_o_8h}\index{/Users/carloshergar/optica/Plasmas/rana-pic/trunk/include/routinesO.h@{/Users/carloshergar/optica/Plasmas/rana-pic/trunk/include/routinesO.h}}
}
This library provides different routines used in the PIC code.  


{\tt \#include $<$stdio.h$>$}\par
{\tt \#include \char`\"{}object.h\char`\"{}}\par
{\tt \#include \char`\"{}laserfield.h\char`\"{}}\par
\subsection*{Functions}
\begin{CompactItemize}
\item 
void \hyperlink{routines_o_8h_9004eb0fd493a525e8ddad245dbf71bc}{CalculaRo} (\hyperlink{classparticle}{particle} $\ast$\_\-elec, \hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, vector$<$ double $>$ \&\_\-qp, double \_\-deltag, int \_\-na, int \_\-np, int \_\-ndg, FILE $\ast$fp0)
\item 
void \hyperlink{routines_o_8h_77518d43e661419f42527294073c1b06}{CalculaJ} (int \_\-label, \hyperlink{classparticle}{particle} $\ast$\_\-elec, \hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, vector$<$ double $>$ \&\_\-qp, double \_\-deltat, double \_\-deltag, int \_\-na, int \_\-np, int \_\-ndg, FILE $\ast$fp0, FILE $\ast$fp1)
\item 
double \hyperlink{routines_o_8h_79dba0e77ba83c0209fed4c3d19a013d}{E0x} (double \_\-xg, double \_\-t)
\item 
double \hyperlink{routines_o_8h_208130229057766f23a1da0d1f524b5c}{E0y} (double \_\-xg, double \_\-t, double \_\-xgleft, \hyperlink{classlaser}{laser} \&\_\-laser0)
\item 
double \hyperlink{routines_o_8h_c0742dcc299f5a1e9685f8df5b7e0e35}{E0z} (double \_\-xg, double \_\-t)
\item 
double \hyperlink{routines_o_8h_c19db2aee940a0ca5bd94c730b8901f6}{B0x} (double \_\-xg, double \_\-t)
\item 
double \hyperlink{routines_o_8h_0f929c5ef0e819fd20e4c93e856e7cfb}{B0y} (double \_\-xg, double \_\-t)
\item 
double \hyperlink{routines_o_8h_f621f839c8269a54bda17738a1f22282}{B0z} (double \_\-xg, double \_\-t, double \_\-xgleft, \hyperlink{classlaser}{laser} \_\-laser0)
\item 
void \hyperlink{routines_o_8h_0bcedda13165a762db3377ded01f517f}{interpola} (double \_\-x, \hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, double \&\_\-Epx, double \&\_\-Epy, double \&\_\-Epz, double \&\_\-Bpx, double \&\_\-Bpy, double \&\_\-Bpz, double \_\-t, int \_\-ndg, double \_\-deltag, int \_\-na, FILE $\ast$fp0)
\item 
void \hyperlink{routines_o_8h_178b26a84c5da4820c2365069ac29161}{ParticleMover} (\hyperlink{classparticle}{particle} \&\_\-elec, double \_\-Epx, double \_\-Epy, double \_\-Epz, double \_\-Bpx, double \_\-Bpy, double \_\-Bpz, double \_\-deltat, double ae)
\item 
void \hyperlink{routines_o_8h_2e5e46e424b846f9cef35189d03c9414}{CalculaCamposInternos} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, double \_\-deltat, double \_\-xgleft, \hyperlink{classlaser}{laser} \_\-laser0, int \_\-ndg, double \_\-deltag, FILE $\ast$fp0)
\item 
void \hyperlink{routines_o_8h_9ee7b9e1180f9ab7e061044d68867cb2}{Charge\_\-deposition} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_6207a7766049f336ecd15a51c1153a18}{Current\_\-deposition} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_c635b212575c845b6e7e7411ea4f4136}{left\_\-one} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_ee07ff7f8fd219ed39ac65b5e21dd367}{left\_\-two\_\-left} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_ce558a7b3a75ef571c7fbc9255732f39}{left\_\-two\_\-right} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_0c335dbd528a038c22a67cef7ecd4ab5}{right\_\-one} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_c748c7cf9fcd556098f48716f26fc00d}{right\_\-two\_\-right} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\item 
void \hyperlink{routines_o_8h_79288e8b7bac0533fff7b3a06c1e0ad6}{right\_\-two\_\-left} (\hyperlink{classcell1d}{cell1d} $\ast$\_\-cell, \hyperlink{classparticle}{particle} \&\_\-elec, double \_\-deltag, double \_\-factor)
\end{CompactItemize}


\subsection{Detailed Description}
This library provides different routines used in the PIC code. 

\begin{Desc}
\item[Author:]Carlos Hernández García $<$\href{mailto:carloshergar@usal.es}{\tt carloshergar@usal.es}$>$, Camilo Ruiz, Enrique Conejero \end{Desc}
\begin{Desc}
\item[Date:]Fri Apr 10 2009\end{Desc}
Copyright (c) 2009 Carlos Hernández García

Carlos Hernández García \par
 $<$\href{mailto:carloshergar@usal.es}{\tt carloshergar@usal.es}$>$ \par
 Universidad de Salamanca \par
 Plaza de la Merced s/n \par
 E-37008 Salamanca, SPAIN \par
 

\subsection{Function Documentation}
\hypertarget{routines_o_8h_c19db2aee940a0ca5bd94c730b8901f6}{
\index{routinesO.h@{routinesO.h}!B0x@{B0x}}
\index{B0x@{B0x}!routinesO.h@{routinesO.h}}
\subsubsection[{B0x}]{\setlength{\rightskip}{0pt plus 5cm}double B0x (double {\em \_\-xg}, \/  double {\em \_\-t})}}
\label{routines_o_8h_c19db2aee940a0ca5bd94c730b8901f6}


This function calculates tue incident magnetic field in the x direction \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-xg}]position \item[{\em \_\-t}]time $\ast$ \item[{\em \_\-cell}]pointer referencing the cell's grid \end{description}
\end{Desc}
\hypertarget{routines_o_8h_0f929c5ef0e819fd20e4c93e856e7cfb}{
\index{routinesO.h@{routinesO.h}!B0y@{B0y}}
\index{B0y@{B0y}!routinesO.h@{routinesO.h}}
\subsubsection[{B0y}]{\setlength{\rightskip}{0pt plus 5cm}double B0y (double {\em \_\-xg}, \/  double {\em \_\-t})}}
\label{routines_o_8h_0f929c5ef0e819fd20e4c93e856e7cfb}


This function calculates tue incident magnetic field in the y direction \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-xg}]position \item[{\em \_\-t}]time $\ast$ \item[{\em \_\-cell}]pointer referencing the cell's grid \end{description}
\end{Desc}
\hypertarget{routines_o_8h_f621f839c8269a54bda17738a1f22282}{
\index{routinesO.h@{routinesO.h}!B0z@{B0z}}
\index{B0z@{B0z}!routinesO.h@{routinesO.h}}
\subsubsection[{B0z}]{\setlength{\rightskip}{0pt plus 5cm}double B0z (double {\em \_\-xg}, \/  double {\em \_\-t}, \/  double {\em \_\-xgleft}, \/  {\bf laser} {\em \_\-laser0})}}
\label{routines_o_8h_f621f839c8269a54bda17738a1f22282}


This function calculates tue incident magnetic field in the z direction \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-xg}]position \item[{\em \_\-t}]time $\ast$ \item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-xgleft}]initial position of the grid \item[{\em \_\-laser0}]\hyperlink{classlaser}{laser} parameters \end{description}
\end{Desc}
\hypertarget{routines_o_8h_2e5e46e424b846f9cef35189d03c9414}{
\index{routinesO.h@{routinesO.h}!CalculaCamposInternos@{CalculaCamposInternos}}
\index{CalculaCamposInternos@{CalculaCamposInternos}!routinesO.h@{routinesO.h}}
\subsubsection[{CalculaCamposInternos}]{\setlength{\rightskip}{0pt plus 5cm}void CalculaCamposInternos ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  double {\em \_\-deltat}, \/  double {\em \_\-xgleft}, \/  {\bf laser} {\em \_\-laser0}, \/  int {\em \_\-ndg}, \/  double {\em \_\-deltag}, \/  FILE $\ast$ {\em fp0})}}
\label{routines_o_8h_2e5e46e424b846f9cef35189d03c9414}


This function calculates the internal fields due to the interaction between particles \begin{Desc}
\item[Version:]2.0 (Birdshall, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-deltat}]temporal increment \item[{\em \_\-xgleft}]init of the spatial grid \item[{\em \_\-laser0}]\hyperlink{classlaser}{laser} parameters \item[{\em \_\-ndg}]number of grid points \item[{\em \_\-deltag}]spatial grid increment \end{description}
\end{Desc}
\hypertarget{routines_o_8h_77518d43e661419f42527294073c1b06}{
\index{routinesO.h@{routinesO.h}!CalculaJ@{CalculaJ}}
\index{CalculaJ@{CalculaJ}!routinesO.h@{routinesO.h}}
\subsubsection[{CalculaJ}]{\setlength{\rightskip}{0pt plus 5cm}void CalculaJ (int {\em \_\-label}, \/  {\bf particle} $\ast$ {\em \_\-elec}, \/  {\bf cell1d} $\ast$ {\em \_\-cell}, \/  vector$<$ double $>$ \& {\em \_\-qp}, \/  double {\em \_\-deltat}, \/  double {\em \_\-deltag}, \/  int {\em \_\-na}, \/  int {\em \_\-np}, \/  int {\em \_\-ndg}, \/  FILE $\ast$ {\em fp0}, \/  FILE $\ast$ {\em fp1})}}
\label{routines_o_8h_77518d43e661419f42527294073c1b06}


This function calculates and distributes the current \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-label}]flag indicating the axis direction (1:x, 2:y, 3:z) \item[{\em \_\-elec}]\hyperlink{classparticle}{particle}, whose charge is distributed \item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-qp}]array of charges of each \hyperlink{classparticle}{particle} \item[{\em \_\-deltat}]temporal increment \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-na}]particle's size \item[{\em \_\-np}]number of particles \item[{\em \_\-ndg}]number of grid points \end{description}
\end{Desc}
\hypertarget{routines_o_8h_9004eb0fd493a525e8ddad245dbf71bc}{
\index{routinesO.h@{routinesO.h}!CalculaRo@{CalculaRo}}
\index{CalculaRo@{CalculaRo}!routinesO.h@{routinesO.h}}
\subsubsection[{CalculaRo}]{\setlength{\rightskip}{0pt plus 5cm}void CalculaRo ({\bf particle} $\ast$ {\em \_\-elec}, \/  {\bf cell1d} $\ast$ {\em \_\-cell}, \/  vector$<$ double $>$ \& {\em \_\-qp}, \/  double {\em \_\-deltag}, \/  int {\em \_\-na}, \/  int {\em \_\-np}, \/  int {\em \_\-ndg}, \/  FILE $\ast$ {\em fp0})}}
\label{routines_o_8h_9004eb0fd493a525e8ddad245dbf71bc}


This function calculates and distributes the charge of one \hyperlink{classparticle}{particle} into its nearest grid points \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-elec}]\hyperlink{classparticle}{particle}, whose charge is distributed \item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-qp}]array of charges of each \hyperlink{classparticle}{particle} \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-na}]particle's size \item[{\em \_\-np}]number of particles \item[{\em \_\-ndg}]number of grid points \end{description}
\end{Desc}
\hypertarget{routines_o_8h_9ee7b9e1180f9ab7e061044d68867cb2}{
\index{routinesO.h@{routinesO.h}!Charge\_\-deposition@{Charge\_\-deposition}}
\index{Charge\_\-deposition@{Charge\_\-deposition}!routinesO.h@{routinesO.h}}
\subsubsection[{Charge\_\-deposition}]{\setlength{\rightskip}{0pt plus 5cm}void Charge\_\-deposition ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_9ee7b9e1180f9ab7e061044d68867cb2}


This function calculates the chrage deposition into the grid cells \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_6207a7766049f336ecd15a51c1153a18}{
\index{routinesO.h@{routinesO.h}!Current\_\-deposition@{Current\_\-deposition}}
\index{Current\_\-deposition@{Current\_\-deposition}!routinesO.h@{routinesO.h}}
\subsubsection[{Current\_\-deposition}]{\setlength{\rightskip}{0pt plus 5cm}void Current\_\-deposition ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_6207a7766049f336ecd15a51c1153a18}


This function calculates the current deposition into the grid cells We distinguish six cases: First, distinguish former position in the first or second half of the cell second, distinguish one one-boundary move and two two-boundary moves \#-boundary move means contributions to \# boundary currents Jx. The currents are calculated from the continuity equation, assuming rectangular \hyperlink{classparticle}{particle} shape and area weighting J.Villasenor and O.Buneman, Comp. Phys. Comm. 69 (1992) 306-316 \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_79dba0e77ba83c0209fed4c3d19a013d}{
\index{routinesO.h@{routinesO.h}!E0x@{E0x}}
\index{E0x@{E0x}!routinesO.h@{routinesO.h}}
\subsubsection[{E0x}]{\setlength{\rightskip}{0pt plus 5cm}double E0x (double {\em \_\-xg}, \/  double {\em \_\-t})}}
\label{routines_o_8h_79dba0e77ba83c0209fed4c3d19a013d}


This function calculates tue incident electric field in the x direction \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-xg}]position \item[{\em \_\-t}]time $\ast$ \item[{\em \_\-cell}]pointer referencing the cell's grid \end{description}
\end{Desc}
\hypertarget{routines_o_8h_208130229057766f23a1da0d1f524b5c}{
\index{routinesO.h@{routinesO.h}!E0y@{E0y}}
\index{E0y@{E0y}!routinesO.h@{routinesO.h}}
\subsubsection[{E0y}]{\setlength{\rightskip}{0pt plus 5cm}double E0y (double {\em \_\-xg}, \/  double {\em \_\-t}, \/  double {\em \_\-xgleft}, \/  {\bf laser} \& {\em \_\-laser0})}}
\label{routines_o_8h_208130229057766f23a1da0d1f524b5c}


This function calculates tue incident electric field in the y direction \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-xg}]position \item[{\em \_\-t}]time $\ast$ \item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-xgleft}]initial position of the grid \item[{\em \_\-laser0}]\hyperlink{classlaser}{laser} parameters \end{description}
\end{Desc}
\hypertarget{routines_o_8h_c0742dcc299f5a1e9685f8df5b7e0e35}{
\index{routinesO.h@{routinesO.h}!E0z@{E0z}}
\index{E0z@{E0z}!routinesO.h@{routinesO.h}}
\subsubsection[{E0z}]{\setlength{\rightskip}{0pt plus 5cm}double E0z (double {\em \_\-xg}, \/  double {\em \_\-t})}}
\label{routines_o_8h_c0742dcc299f5a1e9685f8df5b7e0e35}


This function calculates tue incident electric field in the z direction \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-xg}]position \item[{\em \_\-t}]time $\ast$ \item[{\em \_\-cell}]pointer referencing the cell's grid \end{description}
\end{Desc}
\hypertarget{routines_o_8h_0bcedda13165a762db3377ded01f517f}{
\index{routinesO.h@{routinesO.h}!interpola@{interpola}}
\index{interpola@{interpola}!routinesO.h@{routinesO.h}}
\subsubsection[{interpola}]{\setlength{\rightskip}{0pt plus 5cm}void interpola (double {\em \_\-x}, \/  {\bf cell1d} $\ast$ {\em \_\-cell}, \/  double \& {\em \_\-Epx}, \/  double \& {\em \_\-Epy}, \/  double \& {\em \_\-Epz}, \/  double \& {\em \_\-Bpx}, \/  double \& {\em \_\-Bpy}, \/  double \& {\em \_\-Bpz}, \/  double {\em \_\-t}, \/  int {\em \_\-ndg}, \/  double {\em \_\-deltag}, \/  int {\em \_\-na}, \/  FILE $\ast$ {\em fp0})}}
\label{routines_o_8h_0bcedda13165a762db3377ded01f517f}


This function interpolates the electric and magnetic fields between the cells occuping the \hyperlink{classparticle}{particle} size (na) \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Returns:]electric and magnetic fields in the position of the \hyperlink{classparticle}{particle} \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-x}]\hyperlink{classparticle}{particle} position \item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-Epx}]parameter that returns the electric field in the x-direction \item[{\em \_\-Epy}]parameter that returns the electric field in the y-direction \item[{\em \_\-Epz}]parameter that returns the electric field in the z-direction \item[{\em \_\-Bpx}]parameter that returns the magnetic field in the x-direction \item[{\em \_\-Bpy}]parameter that returns the magnetic field in the y-direction \item[{\em \_\-Bpz}]parameter that returns the magnetic field in the z-direction \item[{\em \_\-t}]time \item[{\em \_\-ndg}]number of grid points \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-na}]particle's size \end{description}
\end{Desc}
\hypertarget{routines_o_8h_c635b212575c845b6e7e7411ea4f4136}{
\index{routinesO.h@{routinesO.h}!left\_\-one@{left\_\-one}}
\index{left\_\-one@{left\_\-one}!routinesO.h@{routinesO.h}}
\subsubsection[{left\_\-one}]{\setlength{\rightskip}{0pt plus 5cm}void left\_\-one ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_c635b212575c845b6e7e7411ea4f4136}


Function related to the calculation of the current deposition: \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_ee07ff7f8fd219ed39ac65b5e21dd367}{
\index{routinesO.h@{routinesO.h}!left\_\-two\_\-left@{left\_\-two\_\-left}}
\index{left\_\-two\_\-left@{left\_\-two\_\-left}!routinesO.h@{routinesO.h}}
\subsubsection[{left\_\-two\_\-left}]{\setlength{\rightskip}{0pt plus 5cm}void left\_\-two\_\-left ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_ee07ff7f8fd219ed39ac65b5e21dd367}


Function related to the calculation of the current deposition: \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_ce558a7b3a75ef571c7fbc9255732f39}{
\index{routinesO.h@{routinesO.h}!left\_\-two\_\-right@{left\_\-two\_\-right}}
\index{left\_\-two\_\-right@{left\_\-two\_\-right}!routinesO.h@{routinesO.h}}
\subsubsection[{left\_\-two\_\-right}]{\setlength{\rightskip}{0pt plus 5cm}void left\_\-two\_\-right ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_ce558a7b3a75ef571c7fbc9255732f39}


Function related to the calculation of the current deposition: \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_178b26a84c5da4820c2365069ac29161}{
\index{routinesO.h@{routinesO.h}!ParticleMover@{ParticleMover}}
\index{ParticleMover@{ParticleMover}!routinesO.h@{routinesO.h}}
\subsubsection[{ParticleMover}]{\setlength{\rightskip}{0pt plus 5cm}void ParticleMover ({\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-Epx}, \/  double {\em \_\-Epy}, \/  double {\em \_\-Epz}, \/  double {\em \_\-Bpx}, \/  double {\em \_\-Bpy}, \/  double {\em \_\-Bpz}, \/  double {\em \_\-deltat}, \/  double {\em ae})}}
\label{routines_o_8h_178b26a84c5da4820c2365069ac29161}


This function uses the Boris algorithm to move the particles, ie, since the fields are known, calculates the velocity and the new position of the particles. (Based on the calculation of the relativistic Lorentz force) \begin{Desc}
\item[Version:]1.0 (Enrique) \end{Desc}
\begin{Desc}
\item[Returns:]\hyperlink{classparticle}{particle} velocity and position, inside the class \hyperlink{classparticle}{particle} called \_\-elec \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-elec}]\hyperlink{classparticle}{particle} \item[{\em \_\-Epx}]electric field in the x-direction acting in that \hyperlink{classparticle}{particle} \item[{\em \_\-Epy}]electric field in the y-direction acting in that \hyperlink{classparticle}{particle} \item[{\em \_\-Epz}]electric field in the z-direction acting in that \hyperlink{classparticle}{particle} \item[{\em \_\-Bpx}]magnetic field in the x-direction acting in that \hyperlink{classparticle}{particle} \item[{\em \_\-Bpy}]magnetic field in the y-direction acting in that \hyperlink{classparticle}{particle} \item[{\em \_\-Bpz}]magnetic field in the z-direction acting in that \hyperlink{classparticle}{particle} \item[{\em ae}]0.5$\ast$qm$\ast$deltat \end{description}
\end{Desc}
\hypertarget{routines_o_8h_0c335dbd528a038c22a67cef7ecd4ab5}{
\index{routinesO.h@{routinesO.h}!right\_\-one@{right\_\-one}}
\index{right\_\-one@{right\_\-one}!routinesO.h@{routinesO.h}}
\subsubsection[{right\_\-one}]{\setlength{\rightskip}{0pt plus 5cm}void right\_\-one ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_0c335dbd528a038c22a67cef7ecd4ab5}


Function related to the calculation of the current deposition: \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_79288e8b7bac0533fff7b3a06c1e0ad6}{
\index{routinesO.h@{routinesO.h}!right\_\-two\_\-left@{right\_\-two\_\-left}}
\index{right\_\-two\_\-left@{right\_\-two\_\-left}!routinesO.h@{routinesO.h}}
\subsubsection[{right\_\-two\_\-left}]{\setlength{\rightskip}{0pt plus 5cm}void right\_\-two\_\-left ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_79288e8b7bac0533fff7b3a06c1e0ad6}


Function related to the calculation of the current deposition: \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
\hypertarget{routines_o_8h_c748c7cf9fcd556098f48716f26fc00d}{
\index{routinesO.h@{routinesO.h}!right\_\-two\_\-right@{right\_\-two\_\-right}}
\index{right\_\-two\_\-right@{right\_\-two\_\-right}!routinesO.h@{routinesO.h}}
\subsubsection[{right\_\-two\_\-right}]{\setlength{\rightskip}{0pt plus 5cm}void right\_\-two\_\-right ({\bf cell1d} $\ast$ {\em \_\-cell}, \/  {\bf particle} \& {\em \_\-elec}, \/  double {\em \_\-deltag}, \/  double {\em \_\-factor})}}
\label{routines_o_8h_c748c7cf9fcd556098f48716f26fc00d}


Function related to the calculation of the current deposition: \begin{Desc}
\item[Version:]2.0 (Villasenor\&Buneman, Lichters) \end{Desc}
\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em \_\-cell}]pointer referencing the cell's grid \item[{\em \_\-elec}]\hyperlink{classparticle}{particle} whose charge we distribute into the cell's grid \item[{\em \_\-deltag}]spatial grid increment \item[{\em \_\-factor}]parameter to adecuate the lichters units to our atomic units, which is: nc$\ast$thickness/deltag/np \end{description}
\end{Desc}
